from django import forms
from vote.models import Vote, VoteOption, VoteResult
from user.models import User


class VoteForm(forms.Form):
    pass


class CreateVote(forms.ModelForm):
    class Meta:
        model = Vote
        user = forms.ModelMultipleChoiceField(queryset=User.objects.all())
        fields = ('user', 'info', 'multiple_selection', 'other_people_add_select')


class CreateVoteOption(forms.ModelForm):
    class Meta:
        model = VoteOption
        user = forms.ModelMultipleChoiceField(queryset=User.objects.all())
        vote = forms.ModelMultipleChoiceField(queryset=Vote.objects.all())
        fields = ('user', 'vote', 'content')
